package com.example.demo_aidl_server

import android.app.Service
import android.content.Intent
import android.os.IBinder

/**
 * @author yaotianxue
 * @description
 * @date 2025/2/18
 */
class CarService:Service() {
    override fun onBind(intent: Intent?): IBinder? {
        return  binder
    }

    val binder:IBinder = object :IMyAidlInterface.Stub(){
        override fun sum(num1: Int, num2: Int): Int {
            Thread.sleep(3000)
            return num1+num2
        }

        override fun sumAsync(num1: Int, num2: Int) {
            Thread.sleep(3000)
        }

    }




}